//
//  AdMoreNativeAd.h
//  AdMoreSDK
//
//  Created by Hayder on 2023/5/14.
//  信息流广告

#import <UIKit/UIKit.h>
#import "AdMoreBaseAd.h"

NS_ASSUME_NONNULL_BEGIN

@class AdMoreNativeAd;
@protocol AdMoreNativeAdDelegate <NSObject>

@optional
/**信息流渲染成功*/
- (void)nativeAdViewRenderSuccess:(UIView *)nativeAdView nativeAd:(AdMoreNativeAd *)nativeAd;
/**信息流渲染失败*/
- (void)nativeAdViewFailedToRender:(UIView *)nativeAdView nativeAd:(AdMoreNativeAd *)nativeAd error:(NSError *)error;

/**展示成功**/
- (void)nativeAdViewWillExpose:(UIView *)nativeAdView nativeAd:(AdMoreNativeAd *)nativeAd;
/**信息流点击事件**/
- (void)nativeAdViewDidClick:(UIView *)nativeAdView nativeAd:(AdMoreNativeAd *)nativeAd;
/**信息流关闭事件*/
- (void)nativeAdViewDidClose:(UIView *)nativeAdView nativeAd:(AdMoreNativeAd *)nativeAd;

/**视频完成播放**/
- (void)nativeAdViewPlayerDidPlayFinish:(UIView *)nativeAdView nativeAd:(AdMoreNativeAd *)nativeAd;
/**视频播放，可能回调多次，暂停->继续播放也会回调**/
- (void)nativeAdViewVideoDidPlaying:(UIView *)nativeAdView nativeAd:(AdMoreNativeAd *)nativeAd;
/**视频暂停播放**/
- (void)nativeAdViewVideoDidPause:(UIView *)nativeAdView nativeAd:(AdMoreNativeAd *)nativeAd;

@end

@interface AdMoreNativeAd : AdMoreBaseAd

@property (nonatomic, weak) id<AdMoreNativeAdDelegate> delegate;

- (instancetype)initWithPlatformAd:(id)platformAd rootController:(UIViewController *)rootViewController;

- (UIView *)renderContentView;

@end

NS_ASSUME_NONNULL_END
